<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>XProject</title>
	<link rel="stylesheet" type="text/css" href="jquery/jquery-easyui/themes/default/easyui.css">
	<link rel="stylesheet" type="text/css" href="jquery/jquery-easyui/themes/icon.css">
	
	<link rel="stylesheet" type="text/css" href="css/expand-icon.css">
	<link rel="stylesheet" type="text/css" href="css/main.css"/>
	<link rel="stylesheet" type="text/css" href="css/type/type.css"/>
	
	<script src="jquery/jquery-1.5.2.min.js" type="text/javascript"></script>
	<script type="text/javascript" src="jquery/jquery-easyui/jquery.easyui.min.js"></script>
	<script type="text/javascript" src="jquery/jquery-easyui/locale/easyui-lang-zh_CN.js"></script>
	
	
	<script type="text/javascript" src="js/main.js"></script>
	
	<style>
		<!--
		.a01:active {
			font-family: "宋体";
			color:#0099FF;
			text-decoration: none;
		}
		.a01:visited {
			font-weight: normal;
			font-variant: normal;
			color:#0099FF;
			text-decoration: none;
			font-family: "宋体";
		}
		.a01:hover {
			font-family: "宋体";
			color:#0099FF;
			text-decoration: underline;
		}
	    
		#nav ul {
		    margin: 0px;
		    height: 16px;
		    padding:10px 0px 0px 30px;
		    list-style-type: none;
		    list-style-image: url('css/icons/jpdlChart.png');
		    vertical-align: middle;
		}
		#nav ul li {
			margin-top: 0px;
		    margin-right: 0px;
		    margin-bottom: auto;
		    margin-left: 0px;
		    font-size: 13px;
		}
		
		div b{
			border-left: 1px solid #0000ff;
			margin-left: 6px;
			padding-left: 8px;
		}
		
		-->
	</style>
	<script language='javascript'>
		function onExist(){
			$.messager.confirm('退出', '您真的要退出本系统吗?', function(r){
				if (r){
					jQuery.ajax({
						type: "POST",
						url:"logout.action", success: function(html){
							window.open("about:blank", "_self");
							window.close(); 
						},error : function(){
							window.open("about:blank", "_self");
							window.close();
						}
					});
				}
			});
		}
	</script>
</head>

<body class="easyui-layout" scrolling="auto">

		<div region="north" style="height:32px;padding:0px 20px 0px 5px;background:#E7EFFF 0 0 repeat-x;">
			<div style="float:left;"><IMG border=0 src="images/logo.png"/></div>
			<div style="line-height:30px;vertical-align:middle; float:right;">
				您好，${user.realName}<b><a href="javascript:editPassword();">修改密码</a></b>
				<b><A href="logout.action">注销</A></b>
				<b><A href="javascript:onExist()">退出</A></b>
			    <b><A href="javascript:aboutCompany()">关于</A></b>
			</div>
		</div>
		
		<div region="west" split="true" title="功能菜单" style="width:200px;padding1:1px;overflow:hidden;" icon="icon-home">
			<div id="aa" class="easyui-accordion" fit="true">
			 <#if menuList?exists && (menuList?size>0)>
				<#list menuList as menuModel>
				   <#if menuModel.id == 10>
				        <div title="${menuModel.text}" icon="icon-model">
						   <ul id="componentsTypeTree"></ul>
						</div>
				   <#else>
						<div title="${menuModel.text}" icon="icon-model" id="nav">
						<#assign functionList= menuModel.children>
							<#list functionList as function>
								<ul>
									<li>
				                     <a class="a01" href="javascript:addTab('${function.text}','${function.url}','');">${function.text}</a>
	                				</li>
	                			</ul>
							</#list>
					    </div>
				  </#if>
				</#list>
			  </#if>
			</div>
		</div>
		
		<div id="mm" class="easyui-menu" style="width:90px;">
	        <div id="mm-tabclose">关闭</div>
	        <div id="mm-tabcloseall">全部关闭</div>
	        <div id="mm-tabcloseother">关闭其他</div>
		</div>
		
		<div region="center">
			<div id="addTabsDiv" class="easyui-tabs" fit="true" border="false">
			</div>
		</div>
</body>
<div id="openPasswordDiv" class="easyui-window" closed="true" modal="true" minimizable="false" collapsible="false" title="修改密码" style="overflow-y:hidden;width:420px;height:220px;">
		<iframe scrolling="auto" id='openPasswordIframe' frameborder="0"  src="" style="width:100%;height:100%;"></iframe>
</div>
<div id="aboutDiv" class="easyui-window" closed="true" modal="true" maximizable="false" minimizable="false" collapsible="false" title="关于" style="overflow-y:hidden;width:510px;height:180px;">
		<iframe scrolling="auto" id='aboutFrame' frameborder="0"  src="" style="width:100%;height:100%;"></iframe>
</div>

<script language = "javaScript">
       $(function(){
			$('#componentsTypeTree').tree({
				animate:true,
				url: 'getComponentsTypeTreeRoot.action',
				onClick:function(node){
					$(this).tree('toggle', node.target);
					 var nodeIds=node.id.split("_");
				     var comTypeId=nodeIds[0];
					 addTab1('元器件信息管理','commondityinfos_manager.action?comTypeID='+comTypeId,'');
				}
			});
		});
		
		function editPassword(){
			$('#openPasswordIframe')[0].src='gotoEditPassword.action';
			$('#openPasswordDiv').window('open');
		}
		function aboutCompany(){
			$('#aboutFrame')[0].src='almsMessage.action';
			$('#aboutDiv').window('open');
		}
</script>
</html>

